package nf;

import nf.graph.Group;
import nf.graph.Graph;
import nf.util.Rational;

public class OrganizationalGroup extends Group
{
	private Rational edgeCost;
	
	public OrganizationalGroup()
	{
		super();
		edgeCost = null;
	}
	
	public Rational getEdgeCost()
	{
		return edgeCost;
	}
	
	public void setEdgeCost(Rational edgeCost)
	{
		this.edgeCost = edgeCost;
	}
	
	public void setEdgeCost(int edgeCost)
	{
		this.edgeCost = new Rational(edgeCost);
	}
	
	public void setEdgeCost(Integer edgeCost)
	{
		this.edgeCost = new Rational(edgeCost.intValue());
	}
	
	public Group copy()
	{
		Group g = super.copy();
		((OrganizationalGroup) g).setEdgeCost(edgeCost);
		return g;
	}
	
	protected Group createNewInstance()
	{
		return new OrganizationalGroup();
	}
}
